package studentui;

import java.awt.Graphics;
import java.awt.Image;

import javax.swing.JPanel;

public class BackPanel extends JPanel {
	private static final long serialVersionUID = 1L;
	private int width= 0;
	private int height=0;
	
	public BackPanel(int width,int height){
		this.width = width;
		this.height = height;
		setSize(width,height);
		this.setLayout(null);
	}
	
	public void paintComponent(Graphics g){
		Image background = this.getToolkit().getImage("back4.jpg");
		g.drawImage(background, 0, 0, width, height, null);
		repaint();
	}
}
